package com.pope945.mypanel;
import com.cloudgarden.layout.AnchorConstraint;
import com.cloudgarden.layout.AnchorLayout;
import com.util.ReadConfig;

import java.awt.Dimension;

import javax.swing.ImageIcon;
import javax.swing.WindowConstants;
import javax.swing.JFrame;
import javax.swing.JPanel;

/**
* This code was edited or generated using CloudGarden's Jigloo
* SWT/Swing GUI Builder, which is free for non-commercial
* use. If Jigloo is being used commercially (ie, by a corporation,
* company or business for any purpose whatever) then you
* should purchase a license for each developer using Jigloo.
* Please visit www.cloudgarden.com for details.
* Use of Jigloo implies acceptance of these licensing terms.
* A COMMERCIAL LICENSE HAS NOT BEEN PURCHASED FOR
* THIS MACHINE, SO JIGLOO OR THIS CODE CANNOT BE USED
* LEGALLY FOR ANY CORPORATE OR COMMERCIAL PURPOSE.
*/
public class BottomPanel extends javax.swing.JPanel {
	
	private BackGroundPane jPanel1;
	private JPanel jp_url;
	/**
	* Auto-generated main method to display this 
	* JPanel inside a new JFrame.
	*/
	public static void main(String[] args) {
		JFrame frame = new JFrame();
		frame.getContentPane().add(new BottomPanel());
		frame.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
		frame.pack();
		frame.setVisible(true);
	}
	
	public BottomPanel() {
		super();
		initGUI();
	}
	
	private void initGUI() {
		try {
			AnchorLayout thisLayout = new AnchorLayout();
			this.setLayout(thisLayout);
			setPreferredSize(new Dimension(488, 103));
			{
				
				String bottomurl=ReadConfig.readValue("config.ini","url.bottomurl");				
				jp_url = new  ComBrowserUrlPanel(bottomurl);
				this.add(jp_url, new AnchorConstraint(25, 1001, -2, 0, AnchorConstraint.ANCHOR_ABS, AnchorConstraint.ANCHOR_REL, AnchorConstraint.ANCHOR_ABS, AnchorConstraint.ANCHOR_ABS));
				jp_url.setPreferredSize(new java.awt.Dimension(488, 81));
			}
			{
				jPanel1 = new BackGroundPane();
				this.add(jPanel1, new AnchorConstraint(0, 0, 254, 0, AnchorConstraint.ANCHOR_ABS, AnchorConstraint.ANCHOR_ABS, AnchorConstraint.ANCHOR_REL, AnchorConstraint.ANCHOR_ABS));
				jPanel1.setPreferredSize(new java.awt.Dimension(488, 26));
				jPanel1.setImageIcon(new ImageIcon(this.getClass().getResource("/icon/bar/zixunleft.jpg")));
			}
		} catch (Exception e) {
			e.printStackTrace();
		}
	}

}
